1. Field of the Invention
The present invention relates to an image reading apparatus, an image processing apparatus, and a computer program product.
2. Description of the Related Art
In an image reading apparatus that converts light to an electric analog image signal by an image sensor such as a charge-coupled device (CCD) to read an image, an analog image signal obtained by converting incident light from a preset reference original image (a white reference board, a black reference board, and the like) to the electric analog image signal is subjected to signal processing such as gain processing and clamp processing (offset processing), thereby obtaining an image signal having a preset strength (for example, see Japanese Patent Application Laid-Open No. H04-320159). This will be described in detail below, taking an example of the clamp processing.
The clamp processing is performed by a clamp circuit 100 as shown in FIG. 11, during a black pixel output period of the analog image signal output from the CCD. In the black pixel output period, a photoelectric transducer in the CCD is shaded, and hence even if the light (a reflected light from a document) comes in, an output level does not change. The output from the CCD during the black pixel output period is referred to as a “black level” as an absolute black reference. In other words, the clamp circuit 100 fixes the black level by keeping potential during one line constant, to take a black level correction process with respect to the output from the CCD during the black pixel output period, based on the black level. More specifically, as shown in FIG. 11, when a clamp pulse (a clamp signal) is input (asserted), and a switch SW 102 is turned ON, an offset level Vin corresponding to the image signal output from the CCD is set as a clamp level Vclp in a clamp level unit 101. In other words, the offset level Vin of an image signal output from the CCD is set to the clamp level Vclp in the lamp level unit 101, thereby keeping the potential constant.
In the clamp circuit 100, however, the value of the clamp level Vclp may not be set to the offset level Vin due to some factors such as an on-resistance of the switch SW 102, and a leak current between an inside of an analog front end (AFE) IC into which the image signal flows and a pad. In this case, a potential difference ΔV is generated between the clamp level Vclp and the offset level Vin.
Such a potential difference ΔV changes according to a read operation mode, when a read period of one line in a sub scanning direction is set to a different value for each read operation mode such as color and monochrome. Further, when a clamp period, which is an input period of a clamp pulse, is set to a different value for each read operation mode such as color and monochrome, the potential difference ΔV changes according to the read operation mode. The change of the potential difference ΔV with the change of the read operation mode causes a change of the offset level of the image signal output from the CCD, when the read operation mode is changed. Since the black level of the image signal output from the CCD is determined by the offset level of the signal, the black level of the image signal changes due to the change of the offset level.
In other words, in the case of a “color read mode” or a “monochrome read mode”, if the black level is constant at all times, a finished image is beautiful. However, if the read operation mode is changed, the black level of the output image changes, and the black density varies, thereby causing a problem in the finish of the output image.